package com.springcloud.util;

public class RedisExpire {
    private Integer expireSecs;

    private Long  createTime;

    public RedisExpire(Integer expireSecs) {
        this.expireSecs = expireSecs;
        this.createTime= System.currentTimeMillis()/1000;
    }
    public boolean isExpire() {
        long diff = System.currentTimeMillis()/1000-createTime-expireSecs;
        return diff>0;
    }

}
